<template>
  <!-- 放大 -->
  <div class="box" @click="onIconClick">
    <div class="box-con" @click.stop>
      <el-icon class="item-icon" @click="onIconClick">
        <CircleClose />
      </el-icon>
      <slot />
    </div>
  </div>
</template>

<script setup>
import { defineEmits, useSlots } from 'vue'
import { CircleClose } from '@element-plus/icons-vue'
const emits = defineEmits(['close'])
const slot = useSlots()
const onIconClick = () => {
  emits('close')
}
</script>

<style lang="less" scoped>
.box {
  position: absolute;
  top: 0px;
  left: 0px;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  .box-con {
    position: relative;
    top: -27px;
    // height: 540px;
    // width: 960px;
    .item-icon {
      cursor: pointer;
      position: absolute;
      right: -80px;
      top: 0px;
      font-size: 50px;
      &:hover {
        color: rgba(255, 255, 255, 0.5);
      }
    }
  }
}
</style>
